<!DOCTYPE html>
<html>

<head>
    <meta charset="utf-8">
    <meta name="viewport" content="maximum-scale=1.0,minimum-scale=1.0,user-scalable=0,initial-scale=1.0,width=device-width" />
    <meta name="format-detection" content="telephone=no,email=no,date=no,address=no">
    <title>找业务</title>
    <link rel="stylesheet" type="text/css" href="../../../css/aui/aui.css" />
    <style>
        .aui-bar-nav {
            background: #0689FB;
        }

        .col_flex {
            height: calc(100vh-4rem);
            background: #fff;
            display: flex;
            justify-content: center;
            align-items: center;
            flex-direction: column;
        }

        .btn {
            width: 60vw;
            height: 17vw;
        }
    </style>
</head>

<body>

    <div id="app">
        <header class="aui-bar aui-bar-nav">找业务</header>
        <div class="col_flex">
            <img class="btn" src="../../../image/img/btn_img1.png" @click="openWin('specialty')" style="margin:4rem 0;" alt="专业用工">
            <img class="btn" src="../../../image/img/btn_img2.png" @click="openWin('odd_job')" alt="零活">
        </div>
    </div>
</body>
<script src="../../../script/api.js" charset="utf-8"></script>
<script src="../../../script/common/jquery-3.3.1.min.js" charset="utf-8"></script>
<script src="../../../script/common/common.js" charset="utf-8"></script>
<script src="../../../script/common/config.js" charset="utf-8"></script>
<script src="../../../script/common/vue.min.js" charset="utf-8"></script>
<script>
    apiready = function() {
        api.parseTapmode();

        vm.statusBar();
    }

    var vm = new Vue({
        el: "#app",
        data: {},
        methods: {
            openWin(name) {
                var winInfo = {
                    specialty: {
                        name: 'specialty_win',
                        url: './specialty/specialty_win.html'
                    },
                    odd_job: {
                        name: 'odd_job_win',
                        url: './odd_job/odd_job_win.html'
                    }
                };
                open_w(winInfo[name].name, winInfo[name].url);
            },
            statusBar() {
                //沉浸式状态栏
                var systemType = api.systemType;
                var statusBar = api.require('statusBar');
                if (systemType == "ios") {
                    if (navigator.userAgent.indexOf("iPhone") != -1) {
                        $("header").css({
                            "paddingTop": api.safeArea.top + 'px'
                        });
                    }
                } else {
                    statusBar.getStatusBarHeight(function(ret, err) {
                        $("header").css({
                            "paddingTop": ret.statusHeight
                        });
                    });
                }
            },
        }
    });
</script>

</html>
